package com.fast.manager.system.repository;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.fast.commons.repository.BaseMapper;
import com.fast.manager.system.domain.DataDictDetail;

public interface DataDictDetailMapper extends BaseMapper<DataDictDetail> {
	
	/**
	 * 查询所有一级的节点
	 * @return
	 */
	public List<DataDictDetail> findAllDataDictDetailRoot() ;
	
	/**
	 * 根据ID查询子节点
	 * @param id
	 * @return
	 */
	public List<DataDictDetail> findDataDictDetailChild(@Param("dataDictDetail_id") Integer dataDictDetail_id) ;
	
	/**
	 * 根据数据字典查询字典明细
	 * @param companyId
	 * @return
	 */
	public List<DataDictDetail> findDataDictDetailByDataDict(@Param("data_dict_id") Integer data_dict_id) ;
	
	/**
	 * 根据数据字典的编码查询字典明显
	 * @param dict_code
	 * @return
	 */
	public List<DataDictDetail> getDictCombobox(@Param("dict_code") String dict_code) ;
	
	/**
	 * 排序
	 * @param pid
	 * @param id
	 * @return
	 */
	public int nextSort(@Param("pid") Long pid, @Param("id") Long id);
	
	
}